<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets">
    <ui:composition template="structpage/templates/defaultLayoutlogin.xhtml">
        <ui:define name="title">
            <h:outputText value="ChequeTeatinos" />
        </ui:define>
        <ui:define name="content">
            <h2> Admin - ChequeTeatinos</h2>
            <div id="formulario">
                <h:form>
                    <div class="form_settings">
                        <p>
                            <span>
                                <h:outputLabel value="Email: " />
                            </span>
                            <h:inputText id="emailTextField" value="#{loginBean.email}" required="true" label="E-Mail" validatorMessage="Formato de e-mail incorrecto."/>
                        </p>
                        <p>
                            <span>
                                <h:outputLabel value="Password: "/>
                            </span>
                            <h:inputSecret id="passwordTextField" value="#{loginBean.password}" required="true" label="Password"/>
                            <br/>
                            <h:commandButton id="doLogin" value="Login" action="#{loginBean.doLoginAdmin()}" styleClass="submit"/>
                        </p>
                        
                    </div>
                    <p>
                        <span><h:message for="emailTextField" styleClass="error"/><br/></span>
                    </p>
                    <p>
                        <span><h:message for="passwordTextField" styleClass="error"/><br/></span>
                    </p>
                    <p>
                        <span><h:outputLabel value="#{loginBean.error}" styleClass="error"/><br/></span>
                    </p>
                </h:form>
            </div>
        </ui:define>
    </ui:composition>
</html>